<template>
  <nav class="weGame-nav">
    <div class="weGame-nav-logo"></div>
    <ul class="weGame-nav-list">
      <li class="weGame-nav-list-item" :key='index' v-for="(item,index) in menuList">
        {{item.name}}
      </li>
    </ul>
    <div class="weGame-nav-wraps-icon">
      <div>
        <field-time-outlined class="weGame-nav-icon" />
      </div>
      <div>
        <appstore-outlined class="weGame-nav-icon" />
      </div>
      <div class="weGame-nav-figure">
        <img src="https://shp.qpic.cn/tgp_hpic/0/940dd737e7849661b06cd2b98291ebdd/0" alt="">
      </div>
    </div>
  </nav>
</template>

<script>
import { defineComponent, reactive } from "vue";
import { AppstoreOutlined, FieldTimeOutlined } from "@ant-design/icons-vue"; //icon
import menu from "./config/menu"; //menu 菜单配追
export default defineComponent({
  components: {
    AppstoreOutlined,
    FieldTimeOutlined,
  },
  setup() {
    const menuList = reactive(menu); //menu菜单
    return {
      menuList,
    };
  },
});
</script>

<style scoped lang="less">
@white: rgba(255, 255, 255, 0.8);
.right () {
  margin-right: 20px;
}
.weGame-nav {
  height: 60px;
  width: 100vw;
  background: rgba(30, 30, 32, 0.85);
  -webkit-app-region: drag;
  display: flex;
  align-items: center;
  justify-content: space-between;
  &-logo {
    background-image: url(https://wegame.gtimg.com/g.55555-r.c4663/rail/fragments/header/icon-logo.a4edc358.svg);
    background-repeat: no-repeat;
    background-position: 10px center;
    width: 180px;
    height: 100%;
  }
  &-wraps-icon {
    display: flex;
  }
  &-icon {
    color: @white;
    font-size: 25px;
    .right();
  }
  &-figure {
    height: 25px;
    width: 25px;
    border-radius: 200px;
    overflow: hidden;
    .right();
    img {
      width: 100%;
      object-fit: contain;
    }
  }
  &-list {
    display: flex;
    color: @white;
    cursor: pointer;
    flex: 1;
    &-item {
      margin-left: 10px;
    }
  }
}
</style>